package com.taotao.rest.webservice;

import java.io.IOException;

import javax.jws.WebService;

import org.apache.solr.client.solrj.SolrServerException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.taotao.rest.pojo.SearchResult;
import com.taotao.rest.service.SolrService;
@Component
@WebService(serviceName="SearchWebService", endpointInterface="com.taotao.rest.webservice.SearchWebService")
public class SearchWebServiceImpl implements SearchWebService {
	@Autowired
	private SolrService solrService;

	@Override
	public SearchResult search(String query, int page, int rows) throws IOException, SolrServerException {
		// TODO Auto-generated method stub
		return solrService.search(query, page, rows);
	}
	
	

}
